import React from 'react';
import Top from "./Top.jsx";
import {useState} from 'react'
import UserList from "./userList.jsx";
import './search.scss'
function Search(props) {
    const [userList, setUserList] = useState([])
    function updateList(userList){
        setUserList(userList)
    }
    return (
        <div className={"search-body"}>
            <div className={"search-top"}>
                <Top updateList={updateList} />
            </div>
            <UserList userList={userList} />
        </div>
    );
}

export default Search;